import request from '@/utils/request'

// 查询项目执行记录列表
export function listExecutions(query) {
  return request({
    url: '/system/executions/list',
    method: 'get',
    params: query
  })
}

// 查询项目执行记录详细
export function getExecutions(id) {
  return request({
    url: '/system/executions/' + id,
    method: 'get'
  })
}

// 新增项目执行记录
export function addExecutions(data) {
  return request({
    url: '/system/executions',
    method: 'post',
    data: data
  })
}

// 修改项目执行记录
export function updateExecutions(data) {
  return request({
    url: '/system/executions',
    method: 'put',
    data: data
  })
}

// 删除项目执行记录
export function delExecutions(id) {
  return request({
    url: '/system/executions/' + id,
    method: 'delete'
  })
}

// 申请延期
export function applyDelay(data) {
  return request({
    url: '/system/executions/applyDelay',
    method: 'post',
    data: data
  })
}

// 撤回
export function applyWithdraw(data) {
  return request({
    url: '/system/executions/applyWithdraw',
    method: 'post',
    data: data
  })
}